package com.mxf.code.responsibility_chain;

import com.mxf.code.request.IRequest;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author mxf
 * @version 1.0
 * @description: TODO
 * @date 2023/1/30
 */
@RestController
@RequestMapping("responsibilityChain")
public class ResponsibilityChainController {
    @Autowired
    private ChainPatternDemo chainPatternDemo;

    @GetMapping("test01")
    public IRequest doDemo(IRequest request) {
        return chainPatternDemo.exec(request, request);
    }
}
